package com.tl.juc.job;

import org.junit.Test;

import java.util.concurrent.FutureTask;

/***
 * @Author 徐庶
 * @Slogan 致敬大师，致敬未来的你
 */
public class CreateThread {


    public void thread1(){
        new Thread() {
            @Override
            public void run() {
                // 继承Thread
            }
        }.start();


        new Thread(() -> {
            // 实现Runnable接口
        }).start() ;


        FutureTask<String> futureTask=new FutureTask<String>(() -> {
            return "实现Callable接口";
        });
        new Thread(futureTask).start();
    }

    @Test
    public void test02(){
        //

        // Integer a=123456789012345678901;
        System.out.println(Integer.MAX_VALUE);
        System.out.println(Integer.SIZE);

    }
}
